package com.dabai.iot.core.dubbo;

import com.dabai.iot.core.api.RemoteConsumerService;
import com.dabai.iot.core.entity.ConsumerGroupEntity;
import com.dabai.iot.core.service.IConsumerGroupService;
import lombok.RequiredArgsConstructor;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.stereotype.Service;

/**
 * 消费组服务实现类
 *
 * @author kev1n
 */
@Service
@DubboService
@RequiredArgsConstructor
public class RemoteConsumerServiceImpl implements RemoteConsumerService {

    private final IConsumerGroupService consumerGroupService;

    @Override
    public ConsumerGroupEntity getConsumerByGroupID(String groupID) {
        return consumerGroupService.getCacheByGroupID(groupID);
    }

}
